package com.vcc.data.mapper;

import com.mybatisflex.core.BaseMapper;
import com.vcc.data.entity.UserRate;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.math.BigDecimal;

@Mapper
public interface UserRateMapper extends BaseMapper<UserRate> {

    @Select("SELECT rate FROM vcc_user_rate WHERE user_id = #{userId}")
    public BigDecimal findAuthRateByUserId(@Param("userId") Long userId);


    @Select("SELECT clear_rate FROM vcc_user_rate WHERE user_id = #{userId}")
    public BigDecimal findWithdrawRateByUserId(@Param("userId") Long userId);
}
